package server.main.pojo;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.apache.ibatis.javassist.runtime.Inner;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * @auther MingHsZzz
 * @Date 2022/9/6-18:06
 */

@Data
@TableName("role_permission")
public class RolePermission {

    private Integer id;

    @TableField(value = "role_id")
    private Integer roleId;


    @TableField(value = "permission_id")
    private Integer prtmissionId;

//    @ApiModelField()
    @TableField(value = "gmt_modified", fill = FieldFill.UPDATE)
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    private Date gmtModified;

    @TableField(value = "gmt_create",fill = FieldFill.INSERT)
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    private Date gmtCreate;
}
